@extends('admin.layout.index')

@section('content')
	<div class="col-lg-12">
	    <div class="card">
	        <div class="card-action">
	            模拟前台友情连接的申请
	        </div>
	        <div class="card-content">
	            <form class="col s12" method="post" action="/admin/link/insert?mode={{ $mode }}" enctype="multipart/form-data">
	            	{{ csrf_field() }}
	                <div class="row">
	                    <div class="input-field col s12">
	                        <input id="phone" type="text" class="validate" name="phone" value="{{ old('phone') }}"  id="mima_mima">
	                        <label for="phone" class="">
	                            <span style="font-size:14px">手机号</span>
	                        </label>
	                    </div>
	                </div>
	                <div class="row">
	                    <div class="input-field col s12">
	                        <input id="email" type="email" class="validate" name="email" value="{{ old('email') }}"  id="mima_mima">
	                        <label for="email" class="">
	                            <span style="font-size:14px">邮箱账号</span>
	                        </label>
	                    </div>
	                </div>
	                <div class="row">
	                    <div class="input-field col s12">
	                        <input id="type" type="text" class="validate" name="timelength" value="{{ old('timelength') }}"  id="mima_mima">
	                        <label for="type" class="">
	                            <span style="font-size:14px">开通的天数</span>
	                        </label>
	                    </div>
	                </div>
					@if($mode == 1)
	                <div class="row">
	                    <div class="input-field col s12">
	                        <input id="address" type="text" class="validate" name="words" value="{{ old('words') }}"  id="mima_mima">
	                        <label for="address" class="">
	                            <span style="font-size:14px">文字链接标题</span>
	                        </label>
	                    </div>
	                </div>
					@elseif($mode == 2)
	                <div class="file-field input-field">
				      	<div class="btn">
				       		<span>File</span>
				        	<input type="file" multiple name="image" value="{{ old('image') }}">
				     	</div>			     	
				      	<div class="file-path-wrapper">
				        	<input class="file-path validate" type="text" name="image" value="{{ old('image') }}" placeholder="选择上传的图片连接">
				      	</div>
	   				</div>
					@endif

	   				<div class="row">
	                    <div class="input-field col s12">
	                        <input id="address" type="text" class="validate" name="url" value="{{ old('url') }}"  id="mima_mima">
	                        <label for="address" class="">
	                            <span style="font-size:14px">链接地址</span>
	                        </label>
	                    </div>
	                </div>
	   				<div class="row">
	                    <div class="input-field col s12">
	                        <input id="address" type="text" class="validate" name="contents" value="{{ old('contents') }}"  id="mima_mima">
	                        <label for="address" class="">
	                            <span style="font-size:14px">链接描述</span>
	                        </label>
	                    </div>
	                </div>
	                <div class="row">
		                <div class="input-field col s6">　
							<input type="submit" value="申请" style="width:150px;height:50px;font-weight:bold;font-size:16px;color:#333;margin-left:30px">
							<input type="reset" value="重置" style="width:150px;height:50px;font-weight:bold;font-size:16px;color:red;margin-left:30px">
	                	</div>
	                </div>
	            </form>
	        </div>
	    </div>
	</div>
@endsection

